package com.javaspeak.concurrency.nio.niolet;

import org.apache.log4j.Logger;

import com.javaspeak.concurrency.nio.niolet.client.ClientNiolet;

/**
 * @author John Dickerson
 */
public class ClientNioletMock implements ClientNiolet {

    public Logger logger = Logger.getLogger( ClientNioletMock.class );

    private String messageToSend;


    public ClientNioletMock( String messageToSend ){

        this.messageToSend = messageToSend;
    }


    /* (non-Javadoc)
     * @see com.javaspeak.nio.client.ClientNiolet#getMessageToSend()
     */
    public String getMessageToSend() {

        return messageToSend;
    }


    /* (non-Javadoc)
     * @see com.javaspeak.nio.client.ClientNiolet#doResponse(java.lang.String)
     */
    public String doResponse( String response ) {

        //logger.debug( "\n" + messageToSend + "\n" + response );
        return response;
    }
}
